package dao.lmp;

import dao.UserDao;
import domain.User;
import utils.JDBCutil;

import java.sql.SQLException;

public class UserDaoimp implements UserDao {


    @Override
    public int addUser(User loginUser) throws SQLException {
        String sql="insert into lol(name,password,address) values(?,?,?)";
        String[] strs={loginUser.getUsername(),loginUser.getPassword(),loginUser.getAddress()};
       // int rs=JDBCutil.excuteUpdate(sql,strs);
        int rs =JDBCutil.excuteUpdate(sql, strs);
        return rs;
    }
}
